package vincent.com.layouttest;

import android.animation.ObjectAnimator;
import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.view.animation.AccelerateDecelerateInterpolator;
import android.view.animation.AccelerateInterpolator;

import java.util.Random;

import vincent.com.layouttest.view.UVView;

/**
 * Created by zhengwenchen on 2016/5/9.
 */
public class UVSampleActivity extends ColorStatusActivity {

    private UVView mUVView;

    @Override
    public View onCreateView(ViewGroup rootView) {
        return LayoutInflater.from(this).inflate(R.layout.activity_uv_sample, rootView, true);
    }

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);

        mUVView = (UVView)findViewById(R.id.uv_view);
    }

    public void smoothScroll(View target){
        Random random = new Random();
        int destLevel = random.nextInt(11);


        mUVView.smoothScrollTo(destLevel);
    }

    @Override
    public String getToolbarTitle() {
        return "UV Sample";
    }
}
